<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="utf-8"/>
<title>插件drag</title>
<link  href="../comboarea/css/jquery-comboarea.css" rel="stylesheet" type="text/css"/> 
<script src="../comboarea/js/jquery.min.js" type="text/javascript"></script>
<script src="../comboarea/js/jquery-comboarea.js" type="text/javascript"></script>
<script type="text/javascript">
 $(function(){
     var  area=[
                {text:"直辖市",value:[{text:"北京",value:1},{text:"天津",value:2}]},
                {text:"广西",value:[{text:"南宁",value:78},{text:"百色",value:81}]}
                ];
	  /*  $("#th").comboarea({ 10.103.234.154
		 data:area
	 });   */
	 var json=[{"city":"巴音郭楞蒙古自治州","sum":"3","lng":"86.12168836","lat":"41.7713622"},
	           {"city":"蚌埠市","sum":"1","lng":"117.3570799","lat":"32.92949891"},
	           {"city":"包头市","sum":"2","lng":"109.8462385","lat":"40.64711943"},
	           {"city":"宝鸡市","sum":"8","lng":"107.1706455","lat":"34.36408081"},
	           {"city":"保定市","sum":"1","lng":"115.4948102","lat":"38.88656455"},
	           {"city":"北京市","sum":"35","lng":"116.395645","lat":"39.92998578"},
	           {"city":"常德市","sum":"1","lng":"111.6537181","lat":"29.01214886"},
	           {"city":"常州市","sum":"2","lng":"119.981861","lat":"31.77139674"},
	           {"city":"成都市","sum":"9","lng":"104.0679235","lat":"30.67994285"},
	           {"city":"赤峰市","sum":"1","lng":"118.9307612","lat":"42.29711232"},
	           {"city":"大理白族自治州","sum":"1","lng":"100.2236748","lat":"25.59689964"},
	           {"city":"大连市","sum":"6","lng":"121.5934778","lat":"38.94870994"},
	           {"city":"大庆市","sum":"3","lng":"125.0218397","lat":"46.59670902"},
	           {"city":"大同市","sum":"1","lng":"113.2905087","lat":"40.1137445"},
	           {"city":"东莞市","sum":"3","lng":"113.763434","lat":"23.04302382"},
	           {"city":"佛山市","sum":"2","lng":"113.1340256","lat":"23.03509484"},
	           {"city":"福州市","sum":"8","lng":"119.3302211","lat":"26.0471255"},
	           {"city":"赣州市","sum":"1","lng":"114.9359091","lat":"25.84529554"},
	           {"city":"广州市","sum":"18","lng":"113.3076497","lat":"23.1200491"},
	           {"city":"贵阳市","sum":"6","lng":"106.7091771","lat":"26.62990674"},
	           {"city":"桂林市","sum":"1","lng":"110.2609201","lat":"25.26290125"},
	           {"city":"哈尔滨市","sum":"4","lng":"126.6577169","lat":"45.77322463"},
	           {"city":"海口市","sum":"3","lng":"110.3308018","lat":"20.02207128"},
	           {"city":"海南省直辖县级行政单位","sum":"1","lng":"109.7337555","lat":"19.1805008"},
	           {"city":"邯郸市","sum":"2","lng":"114.4826939","lat":"36.60930793"},
	           {"city":"杭州市","sum":"8","lng":"120.2193754","lat":"30.25924446"},
	           {"city":"合肥市","sum":"4","lng":"117.2826991","lat":"31.86694226"},
	           {"city":"衡阳市","sum":"1","lng":"112.5838188","lat":"26.89816442"},
	           {"city":"呼和浩特市","sum":"5","lng":"111.6603505","lat":"40.82831887"},
	           {"city":"呼伦贝尔市","sum":"1","lng":"119.7608218","lat":"49.20163605"},
	           {"city":"怀化市","sum":"1","lng":"109.9869588","lat":"27.5574829"},
	           {"city":"淮安市","sum":"1","lng":"119.0301864","lat":"33.60651274"},
	           {"city":"黄石市","sum":"1","lng":"115.0506832","lat":"30.21612713"},
	           {"city":"惠州市","sum":"1","lng":"114.4106581","lat":"23.11353985"},
	           {"city":"吉安市","sum":"1","lng":"114.9920387","lat":"27.11384765"},
	           {"city":"济南市","sum":"4","lng":"117.0249671","lat":"36.68278473"},
	           {"city":"济宁市","sum":"2","lng":"116.6007976","lat":"35.40212166"},
	           {"city":"佳木斯市","sum":"1","lng":"130.2847346","lat":"46.8137796"},
	           {"city":"嘉兴市","sum":"1","lng":"120.7604277","lat":"30.77399224"},
	           {"city":"金华市","sum":"2","lng":"119.6525757","lat":"29.10289911"},
	           {"city":"锦州市","sum":"1","lng":"121.1477487","lat":"41.13087888"},
	           {"city":"晋城市","sum":"1","lng":"112.8673328","lat":"35.49983447"},
	           {"city":"晋中市","sum":"1","lng":"112.7385144","lat":"37.69336153"},
	           {"city":"酒泉市","sum":"1","lng":"98.50841451","lat":"39.74147377"},
	           {"city":"开封市","sum":"1","lng":"114.3516421","lat":"34.80185418"},
	           {"city":"昆明市","sum":"4","lng":"102.7146011","lat":"25.0491531"},
	           {"city":"拉萨市","sum":"2","lng":"91.1118909","lat":"29.66255706"},
	           {"city":"兰州市","sum":"5","lng":"103.8233054","lat":"36.06422553"},
	           {"city":"廊坊市","sum":"1","lng":"116.7036022","lat":"39.51861063"},
	           {"city":"乐山市","sum":"1","lng":"103.7608242","lat":"29.60095761"},
	           {"city":"连云港市","sum":"2","lng":"119.1738722","lat":"34.60154897"},
	           {"city":"辽源市","sum":"4","lng":"125.1336861","lat":"42.92330262"},
	           {"city":"临沂市","sum":"2","lng":"118.3407682","lat":"35.07240907"},
	           {"city":"泸州市","sum":"1","lng":"105.4439703","lat":"28.8959298"},
	           {"city":"绵阳市","sum":"1","lng":"104.705519","lat":"31.50470126"},
	           {"city":"牡丹江市","sum":"1","lng":"129.6080354","lat":"44.58852115"},
	           {"city":"南昌市","sum":"2","lng":"115.8935275","lat":"28.689578"},
	           {"city":"南充市","sum":"1","lng":"106.105554","lat":"30.80096517"},
	           {"city":"南京市","sum":"10","lng":"118.7780744","lat":"32.0572355"},
	           {"city":"南宁市","sum":"4","lng":"108.2972336","lat":"22.80649294"},
	           {"city":"南平市","sum":"1","lng":"118.1818829","lat":"26.64362647"},
	           {"city":"南通市","sum":"4","lng":"120.873801","lat":"32.01466454"},
	           {"city":"内江市","sum":"1","lng":"105.073056","lat":"29.59946153"},
	           {"city":"宁波市","sum":"2","lng":"121.579006","lat":"29.88525897"},
	           {"city":"攀枝花市","sum":"2","lng":"101.7224232","lat":"26.58757126"},
	           {"city":"秦皇岛市","sum":"1","lng":"119.6043676","lat":"39.94546157"},
	           {"city":"青岛市","sum":"3","lng":"120.3844282","lat":"36.1052149"},
	           {"city":"清远市","sum":"1","lng":"113.0407733","lat":"23.69846855"},
	           {"city":"曲靖市","sum":"1","lng":"103.7825389","lat":"25.52075814"},
	           {"city":"泉州市","sum":"3","lng":"118.6003623","lat":"24.90165238"},
	           {"city":"厦门市","sum":"3","lng":"118.103886","lat":"24.48923061"},
	           {"city":"上海市","sum":"27","lng":"121.4878995","lat":"31.24916171"},
	           {"city":"韶关市","sum":"1","lng":"113.5944611","lat":"24.80296031"},
	           {"city":"邵阳市","sum":"1","lng":"111.4615254","lat":"27.23681124"},
	           {"city":"绍兴市","sum":"1","lng":"120.5924674","lat":"30.00236458"},
	           {"city":"深圳市","sum":"15","lng":"114.0259737","lat":"22.54605355"},
	           {"city":"沈阳市","sum":"7","lng":"123.4327909","lat":"41.80864478"},
	           {"city":"石家庄市","sum":"3","lng":"114.5220818","lat":"38.04895831"},
	           {"city":"四平市","sum":"1","lng":"124.3913821","lat":"43.1755247"},
	           {"city":"苏州市","sum":"8","lng":"120.6199071","lat":"31.31798737"},
	           {"city":"台州市","sum":"1","lng":"121.4406129","lat":"28.66828329"},
	           {"city":"太原市","sum":"3","lng":"112.5508636","lat":"37.89027705"},
	           {"city":"泰州市","sum":"2","lng":"119.919606","lat":"32.47605327"},
	           {"city":"唐山市","sum":"2","lng":"118.1834506","lat":"39.65053092"},
	           {"city":"天津市","sum":"7","lng":"117.2108131","lat":"39.1439299"},
	           {"city":"通辽市","sum":"1","lng":"122.2603633","lat":"43.63375607"},
	           {"city":"铜陵市","sum":"1","lng":"117.8194287","lat":"30.94092969"},
	           {"city":"潍坊市","sum":"3","lng":"119.1426338","lat":"36.71611487"},
	           {"city":"温州市","sum":"11","lng":"120.6906347","lat":"28.00283759"},
	           {"city":"乌鲁木齐市","sum":"4","lng":"87.56498774","lat":"43.84038035"},
	           {"city":"无锡市","sum":"8","lng":"120.3054559","lat":"31.57003745"},
	           {"city":"芜湖市","sum":"1","lng":"118.3841084","lat":"31.36601979"},
	           {"city":"武汉市","sum":"8","lng":"114.3162001","lat":"30.58108413"},
	           {"city":"西安市","sum":"3","lng":"108.9530983","lat":"34.2777999"},
	           {"city":"西宁市","sum":"2","lng":"101.767921","lat":"36.64073861"},
	           {"city":"咸阳市","sum":"1","lng":"108.7075093","lat":"34.345373"},
	           {"city":"新乡市","sum":"4","lng":"113.9126902","lat":"35.30725756"},
	           {"city":"宿迁市","sum":"1","lng":"118.2968934","lat":"33.95204973"},
	           {"city":"徐州市","sum":"6","lng":"117.1881066","lat":"34.27155343"},
	           {"city":"烟台市","sum":"3","lng":"121.309555","lat":"37.53656156"},
	           {"city":"延安市","sum":"1","lng":"109.5005098","lat":"36.60332035"},
	           {"city":"盐城市","sum":"4","lng":"120.1488718","lat":"33.37986188"},
	           {"city":"扬州市","sum":"2","lng":"119.4277776","lat":"32.40850525"},
	           {"city":"阳江市","sum":"1","lng":"111.9770098","lat":"21.8715173"},
	           {"city":"宜宾市","sum":"1","lng":"104.6330191","lat":"28.7696748"},
	           {"city":"宜昌市","sum":"1","lng":"111.3109811","lat":"30.73275782"},
	           {"city":"宜春市","sum":"1","lng":"114.4000387","lat":"27.8111299"},
	           {"city":"银川市","sum":"1","lng":"106.2064786","lat":"38.50262101"},
	           {"city":"岳阳市","sum":"2","lng":"113.1461955","lat":"29.37800708"},
	           {"city":"运城市","sum":"1","lng":"111.0068537","lat":"35.03885948"},
	           {"city":"张家口市","sum":"1","lng":"114.8937815","lat":"40.81118849"},
	           {"city":"长春市","sum":"6","lng":"125.3136424","lat":"43.89833761"},
	           {"city":"长沙市","sum":"4","lng":"112.9793528","lat":"28.21347823"},
	           {"city":"长治市","sum":"2","lng":"113.1202921","lat":"36.20166439"},
	           {"city":"郑州市","sum":"7","lng":"113.6496438","lat":"34.75661006"},
	           {"city":"重庆市","sum":"3","lng":"106.530635","lat":"29.54460611"},
	           {"city":"周口市","sum":"1","lng":"114.6541019","lat":"33.62374082"},
	           {"city":"珠海市","sum":"1","lng":"113.562447","lat":"22.25691465"},
	           {"city":"株洲市","sum":"1","lng":"113.1316953","lat":"27.82743293"},
	           {"city":"淄博市","sum":"1","lng":"118.0591343","lat":"36.80468485"},
	           {"city":"遵义市","sum":"1","lng":"106.9312603","lat":"27.69996138"}];
	 var sum=0;
	/*  $.ajax({
			url:'../../js/store.json',
			//async:false,
			success: function(data){
				alert(data.length);
				json=data;
				setJson(json)
		    }
		}); */
		
	 function setJson(){
		 for(var i=0;i<json.length;i++){
			 json[i].count=json[i].sum*1;
			 json[i].point={lng:json[i].lng,lat:json[i].lat};
			 sum=sum+(json[i].sum*1);
			 delete json[i].sum;
			 delete json[i].lng;
			 delete json[i].lat;
		 }
		 $("#th").append(sum);
		 $("#th").append(JSON.stringify(json));
	 };
	 setJson();
	 //alert(sum);
 });
</script>
</head>

<body style="width: 100%;height: 100%;">
   <div id="th" >
    
   </div>
   

</body>
</html>